package me.chyxion.jdbc;

import java.sql.Statement;
import java.sql.SQLException;

/**
 * SQL statement operator
 *
 * @author Donghuang
 * @date Dec 29, 2015 8:12:31 PM
 */
public interface So<T> {

	/**
	 * build statement
     *
	 * @return sql statement
	 * @throws SQLException sql exception caused
	 */
	Statement build() throws SQLException;

	/**
	 * execute statement
	 *
	 * @param statement sql statement
	 * @return execute result
	 * @throws SQLException sql exception caused
	 */
	T exec(Statement statement) throws SQLException;
}
